﻿using System;
using System.Linq;

class ImaginaryNumbersExceptions
{
    static double Sqrt(double number)
    {
        if (number < 0)
        {
            throw new System.ArgumentOutOfRangeException("Invalid number");
        }
        return Math.Sqrt(number);
    }

    static void Main()
    {
        try 
        {	        
		    double number = int.Parse(Console.ReadLine());
            double squareNumber = Sqrt(number);

            Console.WriteLine(squareNumber);
            Console.WriteLine("Good bye!");
        }
        catch
        {
            Console.WriteLine("Invalid number");
        }
    }
}
